<!DOCTYPE HTML>
<html>
	<head>
		<meta http-equiv="Content-Type" content="html/html; charset=utf-8" />
		<title>US2ConditionCollection Class Reference</title>
		<meta id="xcode-display" name="xcode-display" content="render"/>
		<meta name="viewport" content="width=550" />
		<link rel="stylesheet" type="text/css" href="../css/styles.css" media="all" />
		<link rel="stylesheet" type="text/css" media="print" href="../css/stylesPrint.css" />
		<meta name="generator" content="appledoc 2.0.5 (build 789)" />
	</head>
	<body>
		<header id="top_header">
			<div id="library" class="hideInXcode">
				<h1><a id="libraryTitle" href="../index.html">US2FormValidationFramework </a></h1>
				<a id="developerHome" href="../index.html">ustwo™</a>
			</div>
			
			<div id="title" role="banner">
				<h1 class="hideInXcode">US2ConditionCollection Class Reference</h1>
			</div>
			<ul id="headerButtons" role="toolbar">
				<li id="toc_button">
					<button aria-label="Show Table of Contents" role="checkbox" class="open" id="table_of_contents"><span class="disclosure"></span>Table of Contents</button>
				</li>
				<li id="jumpto_button" role="navigation">
					<select id="jumpTo">
	<option value="top">Jump To&#133;</option>
	
	<option value="overview">Overview</option>
	
	
	
	
	<option value="tasks">Tasks</option>
	
	
	
	
	
	<option value="properties">Properties</option>
	
	<option value="//api/name/count">&nbsp;&nbsp;&nbsp;&nbsp;count</option>
	
	
	
	
	
	
	<option value="instance_methods">Instance Methods</option>
	
	<option value="//api/name/addCondition:">&nbsp;&nbsp;&nbsp;&nbsp;- addCondition:</option>
	
	<option value="//api/name/conditionAtIndex:">&nbsp;&nbsp;&nbsp;&nbsp;- conditionAtIndex:</option>
	
	<option value="//api/name/removeCondition:">&nbsp;&nbsp;&nbsp;&nbsp;- removeCondition:</option>
	
	<option value="//api/name/removeConditionAtIndex:">&nbsp;&nbsp;&nbsp;&nbsp;- removeConditionAtIndex:</option>
	
	
	
</select>
				</li>
			</ul>
		</header>
		<nav id="tocContainer" class="isShowingTOC">
			<ul id="toc" role="tree">
				
<li role="treeitem"><span class="nodisclosure"></span><span class="sectionName"><a href="#overview">Overview</a></span></li>




<li role="treeitem" id="task_treeitem"><span class="nodisclosure"></span><span class="sectionName"><a href="#tasks">Tasks</a></span><ul>
	
</ul></li>





<li role="treeitem" class="children"><span class="disclosure"></span><span class="sectionName"><a href="#properties">Properties</a></span><ul>
	
	<li><span class="nodisclosure"></span><span class="sectionName"><a href="#//api/name/count">count</a></span></li>
	
</ul></li>





<li role="treeitem" class="children"><span class="disclosure"></span><span class="sectionName"><a href="#instance_methods">Instance Methods</a></span><ul>
	
	<li><span class="nodisclosure"></span><span class="sectionName"><a href="#//api/name/addCondition:">addCondition:</a></span></li>
	
	<li><span class="nodisclosure"></span><span class="sectionName"><a href="#//api/name/conditionAtIndex:">conditionAtIndex:</a></span></li>
	
	<li><span class="nodisclosure"></span><span class="sectionName"><a href="#//api/name/removeCondition:">removeCondition:</a></span></li>
	
	<li><span class="nodisclosure"></span><span class="sectionName"><a href="#//api/name/removeConditionAtIndex:">removeConditionAtIndex:</a></span></li>
	
</ul></li>


			</ul>
		</nav>
		<article>
			<div id="contents" class="isShowingTOC" role="main">
				<a title="US2ConditionCollection Class Reference" name="top"></a>
				<div class="main-navigation navigation-top">
					<ul>
	<li><a href="../index.html">Index</a></li>
	<li><a href="../hierarchy.html">Hierarchy</a></li>
</ul>
				</div>
				<div id="header">
					<div class="section-header">
						<h1 class="title title-header">US2ConditionCollection Class Reference</h1>
					</div>		
				</div>
				<div id="container">	
					
					<div class="section section-specification"><table cellspacing="0"><tbody>
						<tr>
	<td class="specification-title">Inherits from</td>
	<td class="specification-value">NSObject</td>
</tr><tr>
	<td class="specification-title">Conforms to</td>
	<td class="specification-value">NSFastEnumeration<br /><a href="../Protocols/US2ConditionCollectionProtocol.html">US2ConditionCollectionProtocol</a></td>
</tr><tr>
	<td class="specification-title">Declared in</td>
	<td class="specification-value">US2ConditionCollection.h</td>
</tr>
						</tbody></table></div>
					
					
					
					
					<div class="section section-overview">
						<a title="Overview" name="overview"></a>
						<h2 class="subtitle subtitle-overview">Overview</h2>
						<p>The US2ConditionCollection is internally an array which contains conditions
of type <a href="../Classes/US2Condition.html">US2Condition</a>. Use US2ConditionCollection like an array, but in a
typecasted manner.</p>

<p><em>Example:</em></p>

<pre><code>US2ConditionCollection *conditionCollection = [[US2ConditionCollection alloc] init];

US2Condition *condition1 = [[US2Condition alloc] init];
[conditionCollection addCondition:condition1];
[condition1 release];

US2Condition *condition2 = [conditionCollection conditionAtIndex:0];
[conditionCollection removeCondition:condition2];

BOOL isEmpty = conditionCollection.count == 0;                                          // isEmpty == YES
</code></pre>
					</div>
					
					
					
					
					
					<div class="section section-tasks">
						<a title="Tasks" name="tasks"></a>
						<h2 class="subtitle subtitle-tasks">Tasks</h2>
						
						
						
						

						<ul class="task-list">
							<li>
	<span class="tooltip">
		<code><a href="#//api/name/addCondition:">&ndash;&nbsp;addCondition:</a></code>
		<span class="tooltip"><p>Add a condition to collection.</p></span>
	</span>
	
	
</li><li>
	<span class="tooltip">
		<code><a href="#//api/name/removeCondition:">&ndash;&nbsp;removeCondition:</a></code>
		<span class="tooltip"><p>Remove a condition from collection.</p></span>
	</span>
	
	
</li><li>
	<span class="tooltip">
		<code><a href="#//api/name/removeConditionAtIndex:">&ndash;&nbsp;removeConditionAtIndex:</a></code>
		<span class="tooltip"><p>Remove a condition from collection at index.</p></span>
	</span>
	
	
</li><li>
	<span class="tooltip">
		<code><a href="#//api/name/conditionAtIndex:">&ndash;&nbsp;conditionAtIndex:</a></code>
		<span class="tooltip"><p>Returns a condition of collection at index.</p></span>
	</span>
	
	
</li><li>
	<span class="tooltip">
		<code><a href="#//api/name/count">&nbsp;&nbsp;count</a></code>
		<span class="tooltip"><p>Number of conditions in collection.</p></span>
	</span>
	<span class="task-item-suffix">property</span>
	
</li>
						</ul>
						
					</div>
					
					
					
					
					
					<div class="section section-methods">
						<a title="Properties" name="properties"></a>
						<h2 class="subtitle subtitle-methods">Properties</h2>
						
						<div class="section-method">
	<a name="//api/name/count" title="count"></a>
	<h3 class="subsubtitle method-title">count</h3>
	
	
	
	<div class="method-subsection brief-description">
		<p>Number of conditions in collection.</p>
	</div>		
	
    

	<div class="method-subsection method-declaration"><code>@property (nonatomic, assign, readonly) NSUInteger count</code></div>

    
	
	
	
	
	
	
	
	
	
	
	
	
	
	<div class="method-subsection declared-in-section">
		<h4 class="method-subtitle">Declared In</h4>
		<code class="declared-in-ref">US2ConditionCollection.h</code><br />
	</div>				
	
	
</div>
						
					</div>
					
					
					
					
					
					<div class="section section-methods">
						<a title="Instance Methods" name="instance_methods"></a>
						<h2 class="subtitle subtitle-methods">Instance Methods</h2>
						
						<div class="section-method">
	<a name="//api/name/addCondition:" title="addCondition:"></a>
	<h3 class="subsubtitle method-title">addCondition:</h3>
	
	
	
	<div class="method-subsection brief-description">
		<p>Add a condition to collection.</p>
	</div>		
	
    

	<div class="method-subsection method-declaration"><code>- (void)addCondition:(id&lt;US2ConditionProtocol&gt;)<em>condition</em></code></div>

    
	
	<div class="method-subsection arguments-section parameters">
		<h4 class="method-subtitle parameter-title">Parameters</h4>
		
		<dl class="argument-def parameter-def">
			<dt><em>condition</em></dt>
			<dd><p><a href="../Classes/US2Condition.html">US2Condition</a> instance to add</p></dd>
		</dl>
		
	</div>
	
	
	
	
	
	
	
	
	
	
	
	
	
	<div class="method-subsection declared-in-section">
		<h4 class="method-subtitle">Declared In</h4>
		<code class="declared-in-ref">US2ConditionCollection.h</code><br />
	</div>				
	
	
</div>
						
						<div class="section-method">
	<a name="//api/name/conditionAtIndex:" title="conditionAtIndex:"></a>
	<h3 class="subsubtitle method-title">conditionAtIndex:</h3>
	
	
	
	<div class="method-subsection brief-description">
		<p>Returns a condition of collection at index.</p>
	</div>		
	
    

	<div class="method-subsection method-declaration"><code>- (US2Condition *)conditionAtIndex:(NSUInteger)<em>index</em></code></div>

    
	
	<div class="method-subsection arguments-section parameters">
		<h4 class="method-subtitle parameter-title">Parameters</h4>
		
		<dl class="argument-def parameter-def">
			<dt><em>index</em></dt>
			<dd><p>Index of condition</p></dd>
		</dl>
		
	</div>
	
	
	
	<div class="method-subsection return">
		<h4 class="method-subtitle parameter-title">Return Value</h4>
		<p>Return <a href="../Classes/US2Condition.html">US2Condition</a> instance at index</p>
	</div>
	
	
	
	
	
	
	
	
	
	
	
	<div class="method-subsection declared-in-section">
		<h4 class="method-subtitle">Declared In</h4>
		<code class="declared-in-ref">US2ConditionCollection.h</code><br />
	</div>				
	
	
</div>
						
						<div class="section-method">
	<a name="//api/name/removeCondition:" title="removeCondition:"></a>
	<h3 class="subsubtitle method-title">removeCondition:</h3>
	
	
	
	<div class="method-subsection brief-description">
		<p>Remove a condition from collection.</p>
	</div>		
	
    

	<div class="method-subsection method-declaration"><code>- (void)removeCondition:(id&lt;US2ConditionProtocol&gt;)<em>condition</em></code></div>

    
	
	<div class="method-subsection arguments-section parameters">
		<h4 class="method-subtitle parameter-title">Parameters</h4>
		
		<dl class="argument-def parameter-def">
			<dt><em>condition</em></dt>
			<dd><p><a href="../Classes/US2Condition.html">US2Condition</a> instance to remove</p></dd>
		</dl>
		
	</div>
	
	
	
	
	
	
	
	
	
	
	
	
	
	<div class="method-subsection declared-in-section">
		<h4 class="method-subtitle">Declared In</h4>
		<code class="declared-in-ref">US2ConditionCollection.h</code><br />
	</div>				
	
	
</div>
						
						<div class="section-method">
	<a name="//api/name/removeConditionAtIndex:" title="removeConditionAtIndex:"></a>
	<h3 class="subsubtitle method-title">removeConditionAtIndex:</h3>
	
	
	
	<div class="method-subsection brief-description">
		<p>Remove a condition from collection at index.</p>
	</div>		
	
    

	<div class="method-subsection method-declaration"><code>- (void)removeConditionAtIndex:(NSUInteger)<em>index</em></code></div>

    
	
	<div class="method-subsection arguments-section parameters">
		<h4 class="method-subtitle parameter-title">Parameters</h4>
		
		<dl class="argument-def parameter-def">
			<dt><em>index</em></dt>
			<dd><p><a href="../Classes/US2Condition.html">US2Condition</a> instance to remove at index</p></dd>
		</dl>
		
	</div>
	
	
	
	
	
	
	
	
	
	
	
	
	
	<div class="method-subsection declared-in-section">
		<h4 class="method-subtitle">Declared In</h4>
		<code class="declared-in-ref">US2ConditionCollection.h</code><br />
	</div>				
	
	
</div>
						
					</div>
					
					
				</div>
				<div class="main-navigation navigation-bottom">
					<ul>
	<li><a href="../index.html">Index</a></li>
	<li><a href="../hierarchy.html">Hierarchy</a></li>
</ul>
				</div>
				<div id="footer">
					<hr />
					<div class="footer-copyright">
						<p><span class="copyright">&copy; 2012 ustwo™. All rights reserved. (Last updated: 2012-10-21)</span><br />
						
						<span class="generator">Generated by <a href="http://appledoc.gentlebytes.com">appledoc 2.0.5 (build 789)</a>.</span></p>
						
					</div>
				</div>
			</div>
		</article>
		<script type="text/javascript">
			function jumpToChange()
			{
				window.location.hash = this.options[this.selectedIndex].value;
			}
			
			function toggleTOC()
			{
				var contents = document.getElementById('contents');
				var tocContainer = document.getElementById('tocContainer');
				
				if (this.getAttribute('class') == 'open')
				{
					this.setAttribute('class', '');
					contents.setAttribute('class', '');
					tocContainer.setAttribute('class', '');
					
					window.name = "hideTOC";
				}
				else
				{
					this.setAttribute('class', 'open');
					contents.setAttribute('class', 'isShowingTOC');
					tocContainer.setAttribute('class', 'isShowingTOC');
					
					window.name = "";
				}
				return false;
			}
			
			function toggleTOCEntryChildren(e)
			{
				e.stopPropagation();
				var currentClass = this.getAttribute('class');
				if (currentClass == 'children') {
					this.setAttribute('class', 'children open');
				}
				else if (currentClass == 'children open') {
					this.setAttribute('class', 'children');
				}
				return false;
			}
			
			function tocEntryClick(e)
			{
				e.stopPropagation();
				return true;
			}
			
			function init()
			{
				var selectElement = document.getElementById('jumpTo');
				selectElement.addEventListener('change', jumpToChange, false);
				
				var tocButton = document.getElementById('table_of_contents');
				tocButton.addEventListener('click', toggleTOC, false);
				
				var taskTreeItem = document.getElementById('task_treeitem');
				if (taskTreeItem.getElementsByTagName('li').length > 0)
				{
					taskTreeItem.setAttribute('class', 'children');
					taskTreeItem.firstChild.setAttribute('class', 'disclosure');
				}
				
				var tocList = document.getElementById('toc');
				
				var tocEntries = tocList.getElementsByTagName('li');
				for (var i = 0; i < tocEntries.length; i++) {
					tocEntries[i].addEventListener('click', toggleTOCEntryChildren, false);
				}
				
				var tocLinks = tocList.getElementsByTagName('a');
				for (var i = 0; i < tocLinks.length; i++) {
					tocLinks[i].addEventListener('click', tocEntryClick, false);
				}
				
				if (window.name == "hideTOC") {
					toggleTOC.call(tocButton);
				}
			}
			
			window.onload = init;
			
			// If showing in Xcode, hide the TOC and Header
			if (navigator.userAgent.match(/xcode/i)) {
				document.getElementById("contents").className = "hideInXcode"
				document.getElementById("tocContainer").className = "hideInXcode"
				document.getElementById("top_header").className = "hideInXcode"
			}
			
		</script>
	</body>
</html>